package com.limpo.hello.activity;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.URL;
import java.net.URLConnection;

public class webReader {

	private String str = "";

	public webReader(String str) {
		this.str = str;
	}
	
	public String reader() {
		try {
			URL url = new URL(str);
			URLConnection conn = url.openConnection();
			BufferedReader reader = new BufferedReader(new InputStreamReader(conn.getInputStream()));
			String line = null;
			String returnHTML = "";
			while ((line = reader.readLine()) != null) {
				returnHTML += line + "\n";
			}
			return returnHTML;
		} catch (Exception e) {
			e.printStackTrace();
		}
		return "null";
	}
}
